// React + TS

// 根据初始值自动推断
// 场景：具有非常明确的初始值

import { useState } from "react"

function App() {
	const [value, toggle] = useState(false)

	const [list, setLsit] = useState([1, 2, 3])

	const changeValue = () => {
		toggle(!value)
	}

	const changeList = () => {
		setLsit([...list, 4])
	}

	return (
		<>
			This is App
			<p>{value}</p>
		</>
	)
}

export default App
